var request = require('api.js');
const api = {}
//用户登录
api.autoLign = params => request.https(`/program/login`, 'POST', params)
//获取验证码
api.getVerCode = params => request.https(`/program/gain/code/${params}`, 'POST', {})
//个人业绩及排名
api.getExtIncome = () => request.https(`/program/extension/income`, 'GET', {})
//获取推广中心
api.getExtension = () => request.https(`/program/extension/core`, 'GET', {})
//获取推广nav
api.getProNav = () => request.https(`/program/extension/productListByClassification`, 'GET', {})
//推广海报,产品id,查看推广图集合
api.getAllPosters = (params) => request.https(`/program/extension/pushPage`, 'GET', params)
//推广海报,产品id,查看推广图集合
// api.getAllPosters = (params) => request.https(`/program/extension/getProductPushCode`, 'GET', params)
//订单查询分页,条件搜索
api.getOrderlist = (params) => request.https(`/order/page`, 'GET', params)

//查询所产品
api.getAllProduct = () => request.https(`/order/listProduct`, 'GET', {})

//录单-根据产品类型展示详情
api.getProduct = (id) => request.https(`/program/product/bayId/${id}`, 'GET', {})

//录入新单
api.orderSave = (data) => request.https(`/order/save`, 'POST', data)

//订单状态所有状态查询
api.getOrderState = () => request.https(`/order/state`, 'GET', {})

//查询下面所有团员
api.getListTeam = () => request.https(`/order/listTeam`, 'GET', {})

//查询下面所有团员
api.getOrderDetail = (orderNumber) => request.https(`/order/orderInfo/${orderNumber}`, 'GET', {})

//经纪人未加入:取消申请加入
api.teamCancel = (orderNumber) => request.https(`/program/team/cancel`, 'PUT', {})

//经纪人未加入:申请加入,扫码加入团队接口,和附件团队加入公用
api.teamJoin = (data) => request.https(`/program/team/join`, 'PUT', data)

//获取个人信息
api.getUserInfo = () => request.https(`/program/mine/detail`, 'GET', {})

//获经纪人学院分类
api.getClassBrokerageSchools = (data) => request.https(`/brokerSchool/column`, 'GET', data)

//获经纪人学院列表
api.getBrokerageSchoolsList = (data) => request.https(`/brokerSchool/content`, 'GET', data)

//增加查看经纪人学院文章次数
api.addBrokerageSchoolsnumber = (id) => request.https(`/brokerSchool/contentInfo/${id}`, 'GET', {})

//帖子-点赞,取赞 ,赚钱分享社区0/经纪人学院1/ 类型区分
api.likeOrCancel = (data) => request.https(`/program/forum/praise`, 'PUT', data)

//评论列表（赚钱社区，经纪人学院）
api.getCommentList = (data) => request.https(`/program/comment/page`, 'GET', data)

//二级评论点赞,取赞 （赚钱社区，经纪人学院）
api.level2LikeOrCancel = (id) => request.https(`/program/comment/praiseComment/${id}`, 'POST', {})

//评论--文字评论（赚钱社区，经纪人学院）
api.textReview = (data) => request.https(`/program/comment/add`, 'POST', data)

//评论--文字评论+图片（赚钱社区，经纪人学院）
api.addComment = (data) => request.https(`/program/comment/addComment`, 'POST', data)

//评论--获取上传oss凭证
api.getOssAuth = (data) => request.https(`/program/comment/getOssAuth`, 'GET', data)

//获取账户余额
api.getBalance = () => request.https(`/program/mine/balance`, 'GET', {})
//提现记录
api.getRecordExtract = (data) => request.https(`/program/mine/recordExtract`, 'GET', data)
//收支明细
api.getPaymentDetails = (data) => request.https(`/program/mine/incomePage`, 'GET', data)
//我的银行卡
api.getBankList = () => request.https(`/bank/list`, 'GET', {})

//所有银行卡类型
api.getBankAllList = () => request.https(`/bank/listType`, 'GET', {})

//添加银行卡
api.addBank = (data) => request.https(`/bank/add`, 'POST', data)

//银行卡详情
api.getBankDetail = (id) => request.https(`/bank/byId/${id}`, 'GET', {})

//获取个资料信息
api.getPersonalInfo = () => request.https(`/emp/info`, 'GET', {})

//修改个资料信息
api.putPersonalInfo = (data) => request.https(`/emp/change`, 'PUT', data)

//获取oss上传地址
api.getOSSUrl = () => request.https(`/emp/getMap`, 'GET', {})

//修改/设置密码
api.repairOrSet = (data) => request.https(`/emp/updatePass`, 'PUT', data)

//获取产品列表
api.getProductList = (id) => request.https(`/program/product/list/${id}`, 'GET', {})

//提现限制
api.getCashQuota = () => request.https(`/bank/getCashQuota`, 'GET', {})

//提现
api.applyExtract = (data) => request.https(`/program/mine/applyExtract`, 'POST', data)

//提现状态
api.getExtractInfo = (id) => request.https(`/program/mine/extractInfo/${id}`, 'GET', {})

//推广图
api.getGeneralizeList = (id) => request.https(`/program/product/getGeneralizeList/${id}`, 'GET', {})

//获取房源分类
api.getHousingColumn = () => request.https(`/housing/column`, 'GET', {})

//获取房源列表
api.getHousingList = (data) => request.https(`/housing/content`, 'GET', data)

//获取房源详情
api.getHousingDetail = (id) => request.https(`/housing/contentInfo/${id}`, 'GET', {})

//查看已注册用户业绩
api.getRegisterShow = (data) => request.https(`/program/product/registerShow`, 'GET', data)

//生产海报
api.getRegisterCode = () => request.https(`/program/product/getRegisterCode`, 'GET', {})

//获取用户信息
api.getInfo = () => request.https(`/program/empInfo`, 'GET', {})

//团队信息
api.getTeamInfo = () => request.https(`/program/team/introduce`, 'GET', {})

//经纪人已加入:团队奖金,团队业绩
api.getGross = (data) => request.https(`/program/team/member/gross`, 'GET', data)

//经纪人已加入:展示个人在团队中的排名

api.getRank = () => request.https(`/program/team/member/rank`, 'GET', {})

//合伙人-全名经纪人已加入:团队公告展示
api.getNotice = () => request.https(`/program/team/notice`, 'GET', {})

//合伙人-全名经纪人已加入:团队公告展示
api.getGrade = () => request.https(`/program/team/member/grade`, 'GET', {})

//经纪人已加入:用来展示团队人员的个人订单收入信息
api.getMemberOrder = (data) => request.https(`/program/team/member/order`, 'GET', data)

//经纪人已加入:申请退出团队.取消申请
api.appleExit = () => request.https(`/program/team/apple/exit`, 'POST', {})

//合伙人:合伙人查询个人信息
api.getTeamOwn = () => request.https(`/program/team/own`, 'GET', {})

//合伙人:合伙人查询个人信息
api.getTeamIncome = (data) => request.https(`/program/team/income`, 'GET', data)

//合伙人:修改团队公告内容
api.updateNotice = (data) => request.https(`/program/team/update/notice`, 'PUT', data)

//合伙人:修改团队名称
api.updateTeamName = (data) => request.https(`/program/team/update/name`, 'PUT', data)

//合伙人:邀请成员,展示团队二维码,让人加入
api.getCode = () => request.https(`/program/team/getCode`, 'GET', {})

//合伙人:团队收益
api.getEarnings = (data) => request.https(`/program/team/earnings`, 'GET', data)

//团队是否开放加入
api.isOpenJoin = () => request.https(`/program/team/isOpenJoin`, 'POST', {})

//赚钱分享社区,每个帖子分页查询
api.getCommunityList = (data) => request.https(`/program/forum/page`, 'GET', data)

//赚钱分享社区:id查看帖子详情,带多附件,查看一次添加一次浏览量
api.getCommunityDetail = (id) => request.https(`/program/forum/selectById/${id}`, 'GET', {})

//赚钱分享社区:发布一条帖子(只有内容)
api.addForumContent = (data) => request.https(`/program/forum/addForumContent`, 'POST', data)

//赚钱分享社区:发布一条帖子(内容+文件)
api.addForum = (data) => request.https(`/program/forum/addForum`, 'POST', data)

//经纪人未加入:获取附近团队,默认10000米
api.getNearby = (data) => request.https(`/program/team/nearby`, 'GET', data)

//创建团队
api.teamCreate = (data) => request.https(`/program/team/create`, 'POST', data)
//修改团队位置
api.updateLocation = (data) => request.https(`/program/team/update/location`, 'PUT', data)

//工具-下户工具app:1---查看当前所有下户任务
api.getTaskPage = (data) => request.https(`/survey/taskPage`, 'POST', data)

//带调查详情
api.getAppInfo = (id) => request.https(`/survey/appInfo/${id}`, 'GET', {})

//取消调查
api.returned = (data) => request.https(`/survey/returned`, 'PUT', data)

//申请调查
api.surveyMake = (data) => request.https(`/survey/make`, 'PUT', data)

//到达目的地
api.isArrive = (data) => request.https(`/survey/isArrive`, 'GET', data)

//工具-下户工具:前端获取上传oss凭证
api.surveyGetMap = () => request.https(`/survey/getMap`, 'GET', {})

//工具-下户工具:oss附件成功后,添加后台数据
api.addArriveImg = (data) => request.https(`/survey/addArriveImg`, 'POST', data)

//工具-下户工具:查询当前用户有多少任务
api.getSurveyTaskNum = () => request.https(`/survey/getSurveyTaskNum`, 'GET', {})

//提交调查
api.surveyAddData = (data) => request.https(`/survey/addData`, 'POST', data)

//下户详情
api.surveyDetail = (id) => request.https(`/survey/byId/${id}`, 'GET', {})

//帖子：我的发布
api.myReleaseForumInfo = () => request.https(`/program/forum/myReleaseForumInfo`, 'GET', {})

//删除一条帖子
api.forumDelete = (id) => request.https(`/program/forum/delete/${id}`, 'DELETE', {})

//消息列表
api.getMessage = (data) => request.https(`/msg/page`, 'GET', data)

//获取团队额外奖金规则
api.getTeamExtraRule = () => request.https(`/program/team/getTeamExtraRule`, 'GET', {})

//标记已读
api.alreadyRead = () => request.https(`/msg/alreadyRead`, 'PUT', {})

//单个标记已读
api.msgById = (id) => request.https(`/msg/byId/${id}`, 'GET', {})

//单个删除
api.msmsgDelByIdgById = (id) => request.https(`/msg/delById/${id}`, 'DELETE', {})

//获取未读消息条数
api.getNotReadNum = (id) => request.https(`/msg/getNotReadNum`, 'GET', {})

//团队-扫码详情
api.geTteamBySuperId = (superId) => request.https(`/program/team/bySuperId/${superId}`, 'GET', {})

//邀请注册-邀请人信息
api.getRegisterEmpAppInfo = (id) => request.https(`/emp/getRegisterEmpAppInfo/${id}`, 'GET', {})

//申请加入
api.registerAgent = (data) => request.https(`/app/auto/registerAgent`, 'POST', data)

//邀请注册
api.teamJoin = (data) => request.https(`/program/team/join`, 'PUT', data)

//邀请注册-获取验证码
api.GetAutoRegisterCode = (phoneNumber) => request.https(`/app/auto/registerCode/${phoneNumber}`, 'GET', {})

//绑定账号
api.bindingWeChat = (data) => request.https(`/app/auto/login`, 'POST', data)

//绑定账号-验证码
api.appLoginCode = (phoneNumber) => request.https(`/app/auto/loginCode/${phoneNumber}`, 'GET', {})


//微信登录
api.wxLogin = (code) => request.https(`/app/wx/grant/${code}`, 'GET', {})

//我的推广
api.getMyPromotion = () => request.https(`/program/extension/getMyPromotion`, 'GET', {})

//银行卡-解绑
api.bankDel = (id) => request.https(`/bank/del/${id}`, 'DELETE', {})

//佣金公示
api.getCommissionPublicity = () => request.https(`/program/extension/getCommissionPublicity`, 'GET', {})

//字典
api.plainDictionary = (item) => request.https(`/dictItem/findByDictCode/${item}`, 'GET', {})
//获取活动
api.getActivity = () => request.https(`/program/extension/isOpenActivity`, 'GET', {})
//获取可领取红包次数
api.getRedEnvelopesTimes = () => request.https(`/program/extension/getRedEnvelopesTimes`, 'GET', {})
//获取红包金额
api.getRedEnvelopesMoney = () => request.https(`/program/extension/getRedEnvelopesMoney`, 'GET', {})

//获取朋友圈素材文案数据
api.getCopywritingData = (data) => request.https(`/program/product/getAppCopywritingData`, 'GET', data)

//获取朋友圈素材文案数据
api.getActivityPoster = () => request.https(`/program/extension/getActivityPoster`, 'GET', {})

//查看海报推广线索,业绩展示
api.getExtensionShow = () => request.https(`/program/product/extensionShow`, 'GET', {})


//团队数据统计
api.getBonus = () => request.https(`/mine/bonus`, 'GET', {})

//推广的经纪人
api.getPromotionalAgent = (data) => request.https(`/mine/promotionalAgent`, 'GET', data)


//额外奖金订单
api.getBonusDetails = (data) => request.https(`/mine/bonusDetails`, 'GET', data)

//微信获取手机号
api.getPhone = (data) => request.https(`/app/wx/grantLogin`, 'POST', data)

//微信授权是否已授权过
api.getVerifyBinding = (code) => request.https(`/app/wx/verifyBinding/${code}`, 'GET', {})

//获取分享加盟报名海报
api.getSignUpPoster = () => request.https(`/program/team/getSignUpPoster`, 'GET', {})

//获取下户基本信息
api.getSurveyDataBySid = (data) => request.https(`/survey/getSurveyDataBySid`, 'GET', data)

//上传基本信息
api.addSurveyData = (data) => request.https(`/survey/addSurveyData`, 'POST', data)

//获取下户图片
api.getSurveyAccessoryBySid = (data) => request.https(`/survey/getSurveyAccessoryBySidGroupByType`, 'GET', data)

//上传下户图片(单图片上传)-会返回图片id
api.addArriveImg2 = (data) => request.https(`/survey/addArriveImg2`, 'POST', data)

//获取签到照片
api.getArriveImg = (data) => request.https(`/survey/getArriveImg`, 'GET', data)


//工具-下户工具:删除附件
api.deleteImg = (id) => request.https(`/survey/deleteImg/${id}`, 'DELETE', {})

//获取用户是否上传数据(0正常，1未上传基本信息，2未上传下户图片)
api.getIsUploadData = (data) => request.https(`/survey/getIsUploadData`, 'GET', data)


//提交所有数据，到下一流程
api.surveyDataSubmit = (data) => request.https(`/survey/surveyDataSubmit`, 'POST', data)

//获取验证码
api.getAppraisalCode = (phoneNumber) => request.https(`/appraisal/getAppraisalCode/${phoneNumber}`, 'GET', {})

//提交测额信息
api.submitAppraisalInfo = (data) => request.https(`/appraisal/submitAppraisalInfo`, 'POST', data)

//申请提额/调额
api.applyQuota = (data) => request.https(`/appraisal/applyQuota`, 'POST', data)

//房源详情海报二维码
api.getHouseSharePoster = (id) => request.https(`/housing/getHouseSharePoster/${id}`, 'GET', {})

//积分商城个人信息
api.getPersonInfo = () => request.https(`/integralRecord/personInfo`, 'GET', {});

//今日是否签到
api.isSignToday = () => request.https(`/signin/isSignToday`, 'GET', {});

//签到
api.confirm = () => request.https(`/signin/confirm`, 'POST', {});

//商品分页列表
api.getCommodityInfo = (data) => request.https(`/commodityInfo/page`, 'GET', data);

//积分是否足够
api.isEnough = (cid) => request.https(`/commodityInfo/isEnough/${cid}`, 'GET', {});

//商品兑换
api.exchange = (data) => request.https(`/commodityInfo/exchange`, 'POST', data);

//查询积分汇总
api.integralSummary = () => request.https(`/integralRecord/integralSummary`, 'GET', {});
//积分明细列表
api.integralRecord = (data) => request.https(`/integralRecord/page`, 'GET', data);

//消息推送查询
api.queryMessage = () => request.https(`/html/apply/queryMessage`, 'GET', {});

//消息推送订单详情
api.getQuickAppyDetail = (id) => request.https(`/html/apply/getQuickAppyDetail/${id}`, 'GET', {});

//放弃订单
api.giveOrderApply = (id) => request.https(`/html/apply/giveOrderApply/${id}`, 'POST', {});

//订单跟进
api.followOrder = (id) => request.https(`/html/apply/followOrder/${id}`, 'POST', {});

//修改备注
api.updateNote = (data) => request.https(`/survey/updateNote`, 'POST', data);

//小区定位
api.cellPosition = (id) => request.https(`/survey/cellPosition/${id}`, 'GET',{});

export default api



